{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>BP</th>\n",
       "      <th>Age</th>\n",
       "      <th>Weight</th>\n",
       "      <th>BSA</th>\n",
       "      <th>Dur</th>\n",
       "      <th>Pulse</th>\n",
       "      <th>Stress</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>105</td>\n",
       "      <td>47</td>\n",
       "      <td>85.4</td>\n",
       "      <td>1.75</td>\n",
       "      <td>5.1</td>\n",
       "      <td>63</td>\n",
       "      <td>33</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>115</td>\n",
       "      <td>49</td>\n",
       "      <td>94.2</td>\n",
       "      <td>2.10</td>\n",
       "      <td>3.8</td>\n",
       "      <td>70</td>\n",
       "      <td>14</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>116</td>\n",
       "      <td>49</td>\n",
       "      <td>95.3</td>\n",
       "      <td>1.98</td>\n",
       "      <td>8.2</td>\n",
       "      <td>72</td>\n",
       "      <td>10</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>117</td>\n",
       "      <td>50</td>\n",
       "      <td>94.7</td>\n",
       "      <td>2.01</td>\n",
       "      <td>5.8</td>\n",
       "      <td>73</td>\n",
       "      <td>99</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>112</td>\n",
       "      <td>51</td>\n",
       "      <td>89.4</td>\n",
       "      <td>1.89</td>\n",
       "      <td>7.0</td>\n",
       "      <td>72</td>\n",
       "      <td>95</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    BP  Age  Weight   BSA  Dur  Pulse  Stress\n",
       "0  105   47    85.4  1.75  5.1     63      33\n",
       "1  115   49    94.2  2.10  3.8     70      14\n",
       "2  116   49    95.3  1.98  8.2     72      10\n",
       "3  117   50    94.7  2.01  5.8     73      99\n",
       "4  112   51    89.4  1.89  7.0     72      95"
      ]
     },
     "execution_count": 1,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Import pandas\n",
    "import pandas as pd\n",
    " \n",
    "# Read the blood pressure dataset\n",
    "data = pd.read_csv(\"bloodpress.txt\",sep='\\t')\n",
    " \n",
    "# See the top records in the data\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x7f84da5f8da0>"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Import seaborn\n",
    "import seaborn as sns\n",
    " \n",
    "# Correlation matrix\n",
    "corr=data.corr()\n",
    "\n",
    "# Plot Heatmap on correlation matrix \n",
    "sns.heatmap(corr, annot=True, cmap='YlGnBu')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Gender</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>F</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>M</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>M</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>F</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>M</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "  Gender\n",
       "0      F\n",
       "1      M\n",
       "2      M\n",
       "3      F\n",
       "4      M"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Import pandas module\n",
    "import pandas as pd\n",
    " \n",
    "# Create pandas DataFrame\n",
    "data=pd.DataFrame({'Gender':['F','M','M','F','M']})\n",
    " \n",
    "# Check the top-5 records\n",
    "data.head()\n",
    "\n",
    " \n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>F</th>\n",
       "      <th>M</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   F  M\n",
       "0  1  0\n",
       "1  0  1\n",
       "2  0  1\n",
       "3  1  0\n",
       "4  0  1"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Dummy encoding\n",
    "encoded_data = pd.get_dummies(data['Gender'])\n",
    " \n",
    "# Check the top-5 records of the dataframe\n",
    "encoded_data.head()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>M</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   M\n",
       "0  0\n",
       "1  1\n",
       "2  1\n",
       "3  0\n",
       "4  1"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Dummy encoding\n",
    "encoded_data = pd.get_dummies(data['Gender'], drop_first=True)\n",
    " \n",
    "# Check the top-5 records of the dataframe\n",
    "encoded_data.head()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>TV</th>\n",
       "      <th>Radio</th>\n",
       "      <th>Newspaper</th>\n",
       "      <th>Sales</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>230.1</td>\n",
       "      <td>37.8</td>\n",
       "      <td>69.2</td>\n",
       "      <td>22.1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>44.5</td>\n",
       "      <td>39.3</td>\n",
       "      <td>45.1</td>\n",
       "      <td>10.4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17.2</td>\n",
       "      <td>45.9</td>\n",
       "      <td>69.3</td>\n",
       "      <td>9.3</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>151.5</td>\n",
       "      <td>41.3</td>\n",
       "      <td>58.5</td>\n",
       "      <td>18.5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>180.8</td>\n",
       "      <td>10.8</td>\n",
       "      <td>58.4</td>\n",
       "      <td>12.9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      TV  Radio  Newspaper  Sales\n",
       "0  230.1   37.8       69.2   22.1\n",
       "1   44.5   39.3       45.1   10.4\n",
       "2   17.2   45.9       69.3    9.3\n",
       "3  151.5   41.3       58.5   18.5\n",
       "4  180.8   10.8       58.4   12.9"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Import pandas \n",
    "import pandas as pd\n",
    " \n",
    "# Read the dataset using read_csv method\n",
    "df = pd.read_csv(\"Advertising.csv\")\n",
    " \n",
    "# See the top-5 records in the data\n",
    "df.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [],
   "source": [
    "# Independent variables or Features\n",
    "X = df[['TV', 'Radio', 'Newspaper']] \n",
    " \n",
    "# Dependent or Target variable\n",
    "y = df.Sales \n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [],
   "source": [
    "# Import train_test_split function from \n",
    "from sklearn.model_selection import train_test_split\n",
    " \n",
    "# Split X and y into training and testing sets\n",
    "X_train, X_test, y_train, y_test = train_test_split(X,y,test_size=0.25,random_state=0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "2.89257005115115\n",
      "[0.04416235 0.19900368 0.00116268]\n"
     ]
    }
   ],
   "source": [
    "# Import linear regression model\n",
    "from sklearn.linear_model import LinearRegression\n",
    " \n",
    "# Create linear regression model\n",
    "lin_reg = LinearRegression()\n",
    " \n",
    "# Fit the linear regression model\n",
    "lin_reg.fit(X_train, y_train)\n",
    " \n",
    "# Predict the values given test set\n",
    "predictions = lin_reg.predict(X_test)\n",
    "\n",
    "# Print the intercept and coefficients\n",
    "print(lin_reg.intercept_)\n",
    "print(lin_reg.coef_)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Mean Absolute Error(MAE): 1.300032091923545\n",
      "Mean Squared Error(MSE): 4.0124975229171\n",
      "Root Mean Squared Error(RMSE): 2.003121944095541\n",
      "R2-Square: 0.8576396745320893\n"
     ]
    }
   ],
   "source": [
    "# Import the required libraries\n",
    "import numpy as np\n",
    "from sklearn.metrics import mean_absolute_error\n",
    "from sklearn.metrics import mean_squared_error\n",
    "from sklearn.metrics import r2_score\n",
    " \n",
    "# Evaluate mean absolute error\n",
    "print('Mean Absolute Error(MAE):', mean_absolute_error(y_test,predictions))  \n",
    " \n",
    "# Evaluate mean squared error\n",
    "print(\"Mean Squared Error(MSE):\", mean_squared_error(y_test, predictions))  \n",
    " \n",
    "# Evaluate root mean squared error\n",
    "print(\"Root Mean Squared Error(RMSE):\", np.sqrt(mean_squared_error(y_test, predictions)))\n",
    " \n",
    "# Evaluate R2-square\n",
    "print(\"R2-Square:\",r2_score(y_test, predictions))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Polynomial Regression"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 79,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Text(0, 0.5, 'y-Axis')"
      ]
     },
     "execution_count": 79,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEWCAYAAAB8LwAVAAAABHNCSVQICAgIfAhkiAAAAAlw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9QE9E9B1RXk8WGM3qEOD3EdEbES8DNwJ/VnJNZVstaRJAel5TxJs4IEoiSWR9zEsi4htl11OmiDgvInaJiFayk48/i4im/YYYEU8BT0jaPTUdDPy2xJLKtgI4QNK49P/NwTTxSfvkFuCENH0CcHMRb1K5W200kfcBxwO/kfRAajs/3WrE7LNAV7pp5ePASSXXU5qIuEfS9cB9ZFf/3U8T3XZD0nxgJjBRUg/wZeDvgOsknUIWoB8v5L19qw0zM8vjLiYzM8vlgDAzs1wOCDMzy+WAMDOzXA4IMzPL5YAwG0S64+7vJW2f5iek+WmDrP/rdEliPdv+nm/OaFXny1zNhiDpC8DbIqJD0j8DyyLiopz13gFcB2wPvD0i/tjgUs1GnY8gzIb2TbJf8X4eeD9wySDrfQL4F+A24CgASWMl3StpZpq/SNLcNH27pLY0BsZVaZyD30g6q+g/yKxe/iW12RAi4mVJfw38GDg0Iv40yKrHAh8CdgfOAOZHxHpJJwLXS/oc2T393zPgdTOAyWmcAyRtV8CfYfaq+AjCbHiHk91meq+8hZLeDfRGxHKywVv26xvhKyIeIjuy+Hfg5JyAeRzYTdI/SjoMaMo7+lo1OSDMhiBpBtmRwQHAWZImSZor6YGae2jNBvZId6N9DNgW+IuazbwLeBbYceD2I+IZshHjbgdOxwMmWYU4IMwGke4cejnZWB0rgK8DF0fEnIiYEREzJI0hu1Ha3hHRmu5IO4ssNJD0MeAtZCPEfWdgF5KkicCYiLgB+Bua+7beVjEOCLPBfRpYEREL0vxlZEcKf16zzoHAk2nUsz53AntKmkJ2181TIuJ3wKVkY03Xmgzcno5GrgLOG/0/w+zV8WWuZmaWy0cQZmaWywFhZma5HBBmZpbLAWFmZrkcEGZmlssBYWZmuRwQZmaW638AP2EGsBOkSZ4AAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "# import libraries\n",
    "import matplotlib.pyplot as plt\n",
    "import numpy as np\n",
    "\n",
    "# Create X and Y lists\n",
    "X=[1,2,3,4,5,6,7,8,9,10]\n",
    "y=[9,10,12,16,22,28,40,58,102,200]\n",
    "\n",
    "# Plot scatter diagram\n",
    "plt.scatter(X,y, color = 'red')\n",
    "plt.title('Polynomial Regression')\n",
    "plt.xlabel('X-Axis')\n",
    "plt.ylabel('y-Axis')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 83,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Text(0, 0.5, 'y-Axis')"
      ]
     },
     "execution_count": 83,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEWCAYAAAB8LwAVAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAIABJREFUeJzt3Xu8VHW9//HXG1AUFQEBNRV2Fl45Sf7IS6XiDfB+OUne8po7y0tqN5VSj0V2jlnqz/JEXrMtR1BJ65hplpKJl+0lBBW5BAgi7MQLCiKXz/ljrXEPMBs2uNesmT3v5+Mxj5n5zpq1PnvQ+cz6fL/r+1VEYGZmtqoOeQdgZmaVyQnCzMxKcoIwM7OSnCDMzKwkJwgzMyvJCcLMzEpygrCKIOkKSb/NO45ikk6S9FArt624+NuSpEmSBuUdh5WXE4S1KUkzJC2W9J6keZJulbRp3nGtj4hoiIjBH3c/kgZJWpF+JgslTZZ0elvEWC4RsWtEPJp3HFZeThCWhSMiYlNgd+BzwPdzjqcSvJ5+Jl2BC4FfS9qxrQ8iqVNb79NqlxOEZSYi5gB/BPoDSPqEpPslLZA0VdJZpd4n6X8lnbdK2wRJR6ePQ9LZkqZIekvSLyQpfa2DpO9LmilpvqTfSNo8fa0ufe/pkl5L33u2pM+l+39b0g1FxzxN0uNFz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zM1czMSvIZhJmZleQEYWZmJTlBmJlZSU4QZmZWkhOEmZmV5ARhZmYlOUGYmVlJ/wfJnJysO3+cqQAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "# import libraries\n",
    "import pandas as pd\n",
    "from sklearn.preprocessing import PolynomialFeatures\n",
    "from sklearn.linear_model import LinearRegression\n",
    "\n",
    "# Preprare dataset\n",
    "data = pd.DataFrame({\"X\":[1,2,3,4,5,6,7,8,9,10],\n",
    "                     \"y\":[9,10,12,16,22,28,40,58,102,200]})\n",
    "X = data[['X']]\n",
    "y = data[['y']]\n",
    "\n",
    "# Apply Polynomial Features\n",
    "polynomial_reg = PolynomialFeatures(degree = 6)\n",
    "X_polynomial = polynomial_reg.fit_transform(X)\n",
    "\n",
    "# Apply Linear Regression Model\n",
    "linear_reg = LinearRegression()\n",
    "linear_reg.fit(X_polynomial, y)\n",
    "predictions=linear_reg.predict(X_polynomial)\n",
    "\n",
    "# plot the results\n",
    "plt.scatter(X,y, color = 'red')\n",
    "plt.plot(X, predictions, color = 'blue')\n",
    "plt.title('Polynomial Regression')\n",
    "plt.xlabel('X-Axis')\n",
    "plt.ylabel('y-Axis')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 77,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Text(0, 0.5, 'y-Axis')"
      ]
     },
     "execution_count": 77,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEWCAYAAAB8LwAVAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAIABJREFUeJzt3XmcXFWZ//HP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      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(X,y, color = 'red')\n",
    "plt.plot(X, predictions, color = 'red')\n",
    "plt.title('Polynomial Regression')\n",
    "plt.xlabel('X-Axis')\n",
    "plt.ylabel('y-Axis')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Logistic Regression"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 90,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>pregnant</th>\n",
       "      <th>glucose</th>\n",
       "      <th>bp</th>\n",
       "      <th>skin</th>\n",
       "      <th>insulin</th>\n",
       "      <th>bmi</th>\n",
       "      <th>pedigree</th>\n",
       "      <th>age</th>\n",
       "      <th>label</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>6</td>\n",
       "      <td>148</td>\n",
       "      <td>72</td>\n",
       "      <td>35</td>\n",
       "      <td>0</td>\n",
       "      <td>33.6</td>\n",
       "      <td>0.627</td>\n",
       "      <td>50</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>85</td>\n",
       "      <td>66</td>\n",
       "      <td>29</td>\n",
       "      <td>0</td>\n",
       "      <td>26.6</td>\n",
       "      <td>0.351</td>\n",
       "      <td>31</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>8</td>\n",
       "      <td>183</td>\n",
       "      <td>64</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>23.3</td>\n",
       "      <td>0.672</td>\n",
       "      <td>32</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>89</td>\n",
       "      <td>66</td>\n",
       "      <td>23</td>\n",
       "      <td>94</td>\n",
       "      <td>28.1</td>\n",
       "      <td>0.167</td>\n",
       "      <td>21</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0</td>\n",
       "      <td>137</td>\n",
       "      <td>40</td>\n",
       "      <td>35</td>\n",
       "      <td>168</td>\n",
       "      <td>43.1</td>\n",
       "      <td>2.288</td>\n",
       "      <td>33</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   pregnant  glucose  bp  skin  insulin   bmi  pedigree  age  label\n",
       "0         6      148  72    35        0  33.6     0.627   50      1\n",
       "1         1       85  66    29        0  26.6     0.351   31      0\n",
       "2         8      183  64     0        0  23.3     0.672   32      1\n",
       "3         1       89  66    23       94  28.1     0.167   21      0\n",
       "4         0      137  40    35      168  43.1     2.288   33      1"
      ]
     },
     "execution_count": 90,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Import libraries\n",
    "import pandas as pd\n",
    " \n",
    "# read the dataset\n",
    "diabetes = pd.read_csv(\"diabetes.csv\")\n",
    " \n",
    "# Show top 5-records\n",
    "diabetes.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 94,
   "metadata": {},
   "outputs": [],
   "source": [
    "# split dataset in two parts: feature set and target label \n",
    "feature_set = ['pregnant', 'insulin', 'bmi', 'age','glucose','bp','pedigree']\n",
    "features = diabetes[feature_set] \n",
    "target = diabetes.label\n",
    "\n",
    "# partition data into training and testing set \n",
    "from sklearn.model_selection import train_test_split\n",
    "feature_train, feature_test, target_train, target_test = train_test_split(features, target, test_size=0.3, random_state=1)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 101,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Logistic Regression Model Accuracy: 0.7835497835497836\n"
     ]
    }
   ],
   "source": [
    "# import logistic regression scikit-learn model\n",
    "from sklearn.linear_model import LogisticRegression\n",
    "from sklearn.metrics import accuracy_score # for performance evaluation\n",
    " \n",
    "# instantiate the model\n",
    "logreg = LogisticRegression(solver='lbfgs')\n",
    " \n",
    "# fit the model with data\n",
    "logreg.fit(feature_train,target_train)\n",
    " \n",
    "# Forecast the target variable for given test dataset\n",
    "predictions = logreg.predict(feature_test)\n",
    " \n",
    "# Assess model performance using accuracy measure\n",
    "print(\"Logistic Regression Model Accuracy:\",accuracy_score(target_test, predictions))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
